Conversation
✅ Deploy Preview for rstest-dev ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
3732d08 to
c3f3066
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds an rstest init browser command to scaffold browser testing configuration and example files. The command supports both interactive and non-interactive modes (with --yes flag), auto-detects project settings like framework (React), language (TypeScript/JavaScript), and package manager, then generates appropriate configuration, component, and test files.
Key changes:
- Add interactive CLI initialization with project auto-detection
- Generate browser test configuration and example files
- Automatically update package.json with test scripts and dependencies
Reviewed changes
Copilot reviewed 11 out of 12 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| pnpm-lock.yaml | Add new dependencies for CLI prompts and package manager detection |
| packages/core/src/core/browserLoader.ts | Remove duplicate RSTEST_VERSION declaration (now in env.d.ts) |
| packages/core/src/cli/init/browser/utils.ts | Add utility functions for file operations and package.json updates |
| packages/core/src/cli/init/browser/templates.ts | Add template generators for config, components, and tests |
| packages/core/src/cli/init/browser/index.ts | Export create function for browser initialization |
| packages/core/src/cli/init/browser/detect.ts | Add project detection logic for framework, language, and package manager |
| packages/core/src/cli/init/browser/create.ts | Implement main initialization logic with interactive and non-interactive modes |
| packages/core/src/cli/commands.ts | Register 'init' command with browser subcommand |
| packages/core/package.json | Add new dependencies for CLI functionality |
| packages/core/LICENSE.md | Add license notices for new dependencies |
| package.json | Add Playwright to root dev dependencies |
| e2e/cli/initBrowser.test.ts | Add e2e test for init browser command |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
22805ec to
68274ee
Compare
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
rstest init browsercommand with interactive and--yesmodesrstest.browser.config.ts, example component and test filespackage.jsonwithtest:browserscript and devDependenciesRelated Links
Checklist